package com.yuxi;

/**
 *
 * run  and start different
 * Created by yuxi on 17/1/26.
 */
public class RunDiffStart {
    public  static  void main(String[] args) {
        //这个是线程启动,打出来的是子线程
        MyThread myThread = new MyThread();
        new Thread(myThread).start();
        //这个只是一个普通的Java方法,可以看到打出来的是main线程
        myThread.run();
    }
    static  class  MyThread implements  Runnable {
        public  void run() {
            System.out.println("this is thread name..."+Thread.currentThread().getName());
        }
    }
}
